/**
 *@author Alexander Remen 
 */
package donnees.ressources;

import java.io.Serializable;

public class Ressource implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	protected String type;
	protected float valeur;
	
	public Ressource(String type , float valeur){
		this.type = type;
		this.valeur = valeur;
	}
	
	
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public float getValeur() {
		return valeur;
	}
	public void setValeur(float valeur) {
		this.valeur = valeur;
	}
	
	public boolean isCPU(){
		boolean retour =false; 
		if (this.type.equals("CPU"))
			retour = true;
		return retour;
	}
	
	public boolean isRAM(){
		boolean retour =false; 
		if (this.type.equals("RAM"))
			retour = true;
		return retour;
	}
	
	public boolean isProcess(){
		boolean retour =false; 
		if (this.type.equals("Process"))
			retour = true;
		return retour;
	}
	
	public boolean isHDD(){
		boolean retour =false; 
		if (this.type.equals("HDD"))
			retour = true;
		return retour;
	}
}
